import java.util.Scanner;

/**
 * @Author YuanYuan
 * @Date 2022/4/29
 * @Time 14:50
 */
public class TestDemo {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int n = scanner.nextInt();
        int fab1 = 1;
        int fab2 = 1;
        int temp = 0;
        for (int i = 1; i <= n-2; i++) {
            temp = fab1 + fab2;
            fab1 = fab2;
            fab2 = temp;
        }
        System.out.println(temp);
    }
}
